home *** CD-ROM | disk | FTP | other *** search
/ MacHack 2000 / MacHack 2000.toast / pc / The Hacks / Softshoe / Lisa's Mac Parts / Files / Directories / FileInfoLoop.cp < prev    next >
Text File  |  2000-06-23  |  509b  |  30 lines

  1. // FileInfoLoop.cp
  2.  
  3. #ifndef FileInfoLoop_h
  4. #include "FileInfoLoop.h"
  5. #endif
  6.  
  7. void FileInfoLoop::AdvanceToNextMatch()
  8.   {
  9.     while ( Unfinished() && (*this)->IsDirectory() )
  10.         CatInfoLoop::operator++();
  11.   }
  12.  
  13. FileInfoLoop::FileInfoLoop( Directory folder )
  14.   : CatInfoLoop( folder )
  15.   {
  16.     AdvanceToNextMatch();
  17.   }
  18.  
  19. void FileInfoLoop::Start( Directory folder )
  20.   {
  21.     CatInfoLoop::Start( folder );
  22.     AdvanceToNextMatch();
  23.   }
  24.  
  25. void FileInfoLoop::operator++()
  26.   {
  27.     CatInfoLoop::operator++();
  28.     AdvanceToNextMatch();
  29.   }
  30.